package com.guanzhi.config;

import jakarta.servlet.ServletException;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import org.springframework.security.access.AccessDeniedException;
import org.springframework.security.web.access.AccessDeniedHandler;

import java.io.IOException;

/**
 * Spring Security
 * <p> Package: com.guanzhi.config </p>
 * <p> File: MyAccessDeniedHandler.java </p>
 * <p> Description:  (访问被拒绝处理)</p>
 * <p> Date: 2024/3/30 22:42</p>
 *
 * @author 观之
 * @version 1.0 （代码版本）
 * @email <a href="mailto:guanzhi55634@aliyun.com">观之</a>（邮箱）
 * @date 2024/3/30 22:42
 * @since jdk17（jdk版本）
 */
public class MyAccessDeniedHandler implements AccessDeniedHandler {
    @Override
    public void handle(HttpServletRequest request, HttpServletResponse response, AccessDeniedException accessDeniedException) throws IOException, ServletException {
        //自行实现访问被拒绝处理
    }
}
